// vite.config.ts
import { defineConfig, loadEnv } from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/vite/dist/node/index.js";
import AutoImport from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/unplugin-auto-import/dist/vite.js";
import Components from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/unplugin-vue-components/dist/vite.mjs";
import { ElementPlusResolver } from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/unplugin-vue-components/dist/resolvers.mjs";
import vue from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/@vitejs/plugin-vue/dist/index.mjs";
import { createSvgIconsPlugin } from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/vite-plugin-svg-icons/dist/index.mjs";
import path from "path";
import tailwindcss from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/tailwindcss/lib/index.js";
import autoprefixer from "file:///D:/Users/lwd/Desktop/code1/Ruyu-Blog-master/blog-frontend/kuailemao-blog/node_modules/autoprefixer/lib/autoprefixer.js";
var vite_config_default = defineConfig(({ mode }) => {
  return {
    plugins: [
      vue(),
      createSvgIconsPlugin({
        // 指定需要缓存的图标文件夹
        iconDirs: [path.resolve(process.cwd(), "src/assets/icons")],
        // 指定symbolId格式
        symbolId: "icon-[dir]-[name]"
      }),
      AutoImport({
        imports: ["vue", "vue-router", "pinia"],
        resolvers: [ElementPlusResolver()],
        dts: "src/types/auto-imports.d.ts"
      }),
      Components({
        resolvers: [ElementPlusResolver()],
        dts: "src/types/components.d.ts"
      })
    ],
    resolve: {
      alias: {
        "@": path.resolve("./src")
        // 相对路径别名配置，使用 @ 代替 src
      }
    },
    css: {
      preprocessorOptions: {
        scss: {
          javascriptEnabled: true,
          additionalData: '@import "./src/styles/variable.scss";'
        }
      },
      postcss: {
        plugins: [
          tailwindcss,
          autoprefixer
        ]
      }
    },
    server: {
      port: 99,
      host: "0.0.0.0",
      proxy: {
        "/api": {
          target: `${loadEnv(mode, process.cwd()).VITE_SERVE}`,
          changeOrigin: true,
          rewrite: (path2) => path2.replace(/^\/api/, "")
        },
        "/wapi": {
          target: `${loadEnv(mode, process.cwd()).VITE_MUSIC_SERVE}`,
          changeOrigin: true,
          rewrite: (path2) => path2.replace(/^\/wapi/, "")
        }
      }
    }
  };
});
export {
  vite_config_default as default
};
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCJEOlxcXFxVc2Vyc1xcXFxsd2RcXFxcRGVza3RvcFxcXFxjb2RlMVxcXFxSdXl1LUJsb2ctbWFzdGVyXFxcXGJsb2ctZnJvbnRlbmRcXFxca3VhaWxlbWFvLWJsb2dcIjtjb25zdCBfX3ZpdGVfaW5qZWN0ZWRfb3JpZ2luYWxfZmlsZW5hbWUgPSBcIkQ6XFxcXFVzZXJzXFxcXGx3ZFxcXFxEZXNrdG9wXFxcXGNvZGUxXFxcXFJ1eXUtQmxvZy1tYXN0ZXJcXFxcYmxvZy1mcm9udGVuZFxcXFxrdWFpbGVtYW8tYmxvZ1xcXFx2aXRlLmNvbmZpZy50c1wiO2NvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9pbXBvcnRfbWV0YV91cmwgPSBcImZpbGU6Ly8vRDovVXNlcnMvbHdkL0Rlc2t0b3AvY29kZTEvUnV5dS1CbG9nLW1hc3Rlci9ibG9nLWZyb250ZW5kL2t1YWlsZW1hby1ibG9nL3ZpdGUuY29uZmlnLnRzXCI7aW1wb3J0IHtDb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3NyYy9hc3NldHMvaWNvbnMnKV0sXG4gICAgICAgICAgICAgICAgLy8gXHU2MzA3XHU1QjlBc3ltYm9sSWRcdTY4M0NcdTVGMEZcbiAgICAgICAgICAgICAgICBzeW1ib2xJZDogJ2ljb24tW2Rpcl0tW25hbWVdJyxcbiAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgQXV0b0ltcG9ydCh7XG4gICAgICAgICAgICAgICAgaW1wb3J0czogWyd2dWUnLCAndnVlLXJvdXRlcicsICdwaW5pYSddLFxuICAgICAgICAgICAgICAgIHJlc29sdmVyczogW0VsZW1lbnRQbHVzUmVzb2x2ZXIoKV0sXG4gICAgICAgICAgICAgICAgZHRzOiBcInNyYy90eXBlcy9hdXRvLWltcG9ydHMuZC50c1wiLFxuICAgICAgICAgICAgfSksXG4gICAgICAgICAgICBDb21wb25lbnRzKHtcbiAgICAgICAgICAgICAgICByZXNvbHZlcnM6IFtFbGVtZW50UGx1c1Jlc29sdmVyKCldLFxuICAgICAgICAgICAgICAgIGR0czogXCJzcmMvdHlwZXMvY29tcG9uZW50cy5kLnRzXCIsXG4gICAgICAgICAgICB9KSxcbiAgICAgICAgXSxcbiAgICAgICAgcmVzb2x2ZToge1xuICAgICAgICAgICAgYWxpYXM6IHtcbiAgICAgICAgICAgICAgICBcIkBcIjogcGF0aC5yZXNvbHZlKFwiLi9zcmNcIikgLy8gXHU3NkY4XHU1QkY5XHU4REVGXHU1Rjg0XHU1MjJCXHU1NDBEXHU5MTREXHU3RjZFXHVGRjBDXHU0RjdGXHU3NTI4IEAgXHU0RUUzXHU2NkZGIHNyY1xuICAgICAgICAgICAgfVxuICAgICAgICB9LFxuICAgICAgICBjc3M6IHtcbiAgICAgICAgICAgIHByZXByb2Nlc3Nvck9wdGlvbnM6IHtcbiAgICAgICAgICAgICAgICBzY3NzOiB7XG4gICAgICAgICAgICAgICAgICAgIGphdmFzY3JpcHRFbmFibGVkOiB0cnVlLFxuICAgICAgICAgICAgICAgICAgICBhZGRpdGlvbmFsRGF0YTogJ0BpbXBvcnQgXCIuL3NyYy9zdHlsZXMvdmFyaWFibGUuc2Nzc1wiOycsXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBwb3N0Y3NzOiB7XG4gICAgICAgICAgICAgICAgcGx1Z2luczogW1xuICAgICAgICAgICAgICAgICAgICB0YWlsd2luZGNzcyxcbiAgICAgICAgICAgICAgICAgICAgYXV0b3ByZWZpeGVyLFxuICAgICAgICAgICAgICAgIF1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfSxcbiAgICAgICAgc2VydmVyOiB7XG4gICAgICAgICAgICBwb3J0OiA5OSxcbiAgICAgICAgICAgIGhvc3Q6ICcwLjAuMC4wJyxcbiAgICAgICAgICAgIHByb3h5OiB7XG4gICAgICAgICAgICAgICAgJy9hcGknOiB7XG4gICAgICAgICAgICAgICAgICAgIHRhcmdldDogYCR7bG9hZEVudihtb2RlLCBwcm9jZXNzLmN3ZCgpKS5WSVRFX1NFUlZFfWAsXG4gICAgICAgICAgICAgICAgICAgIGNoYW5nZU9yaWdpbjogdHJ1ZSxcbiAgICAgICAgICAgICAgICAgICAgcmV3cml0ZTogKHBhdGgpID0+IHBhdGgucmVwbGFjZSgvXlxcL2FwaS8sICcnKVxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgJy93YXBpJzoge1xuICAgICAgICAgICAgICAgICAgICB0YXJnZXQ6IGAke2xvYWRFbnYobW9kZSwgcHJvY2Vzcy5jd2QoKSkuVklURV9NVVNJQ19TRVJWRX1gLFxuICAgICAgICAgICAgICAgICAgICBjaGFuZ2VPcmlnaW46IHRydWUsXG4gICAgICAgICAgICAgICAgICAgIHJld3JpdGU6IChwYXRoKSA9PiBwYXRoLnJlcGxhY2UoL15cXC93YXBpLywgJycpXG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgfVxufSlcbiJdLAogICJtYXBwaW5ncyI6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